/** 当路由表太长时，可以将其拆分为小模块 **/

import Layout from 'views/layout/layout'

const mallTradingRouter = {
  path: '/mallTrading',
  component: Layout,
  redirect: 'noredirect',
  name: 'mallTrading',
  meta: {
    title: 'mallTrading',
    icon: 'mallTrading',
    roles: ['demo']
  },
  children: [
    {
      path: 'orderManage',
      component: () => import('pages/mallTrading/orderManage/index'),
      redirect: 'noredirect',
      name: 'orderManage',
      meta: {
        title: 'orderManage'
      },
      children: [
        {
          path: 'tobePaymentOrder',
          component: () => import('pages/mallTrading/orderManage/tobePaymentOrder'),
          name: 'tobePaymentOrder',
          meta: {
            title: 'tobePaymentOrder'
          }
        },
        {
          path: 'tobeDeliverOrder',
          component: () => import('pages/mallTrading/orderManage/tobeDeliverOrder'),
          name: 'tobeDeliverOrder',
          meta: {
            title: 'tobeDeliverOrder'
          }
        },
        {
          path: 'tobeReceiveOrder',
          component: () => import('pages/mallTrading/orderManage/tobeReceiveOrder'),
          name: 'tobeReceiveOrder',
          meta: {
            title: 'tobeReceiveOrder'
          }
        },
        {
          path: 'completedOrder',
          component: () => import('pages/mallTrading/orderManage/completedOrder'),
          name: 'completedOrder',
          meta: {
            title: 'completedOrder'
          }
        },
        {
          path: 'presaleTobePaymentOrder',
          component: () => import('pages/mallTrading/orderManage/presaleTobePaymentOrder'),
          name: 'presaleTobePaymentOrder',
          meta: {
            title: 'presaleTobePaymentOrder'
          }
        },
        {
          path: 'closedOrder',
          component: () => import('pages/mallTrading/orderManage/closedOrder'),
          name: 'closedOrder',
          meta: {
            title: 'closedOrder'
          }
        },
        {
          path: 'goodsCommentSearch',
          component: () => import('pages/mallTrading/orderManage/goodsCommentSearch'),
          name: 'goodsCommentSearch',
          meta: {
            title: 'goodsCommentSearch'
          }
        },
        {
          path: 'allOrdersCollect',
          component: () => import('pages/mallTrading/orderManage/allOrdersCollect'),
          name: 'allOrdersCollect',
          meta: {
            title: 'allOrdersCollect'
          }
        }

      ]
    },
    {
      path: 'refundManage',
      component: () => import('pages/mallTrading/refundManage/index'),
      redirect: 'noredirect',
      name: 'refundManage',
      meta: {
        title: 'refundManage'
      },
      children: [
        {
          path: 'refundAudit',
          component: () => import('pages/mallTrading/refundManage/refundAudit'),
          name: 'refundAudit',
          meta: {
            title: 'refundAudit'
          }
        },
        {
          path: 'completedRefund',
          component: () => import('pages/mallTrading/refundManage/completedRefund'),
          name: 'completedRefund',
          meta: {
            title: 'completedRefund'
          }
        },
        {
          path: 'refundAuditFailed',
          component: () => import('pages/mallTrading/refundManage/refundAuditFailed'),
          name: 'refundAuditFailed',
          meta: {
            title: 'refundAuditFailed'
          }
        }
      ]
    },
    {
      path: 'returnGoodsManage',
      component: () => import('pages/mallTrading/returnGoodsManage/index'),
      redirect: 'noredirect',
      name: 'returnGoodsManage',
      meta: {
        title: 'returnGoodsManage'
      },
      children: [
        {
          path: 'returnGoodsAudit',
          component: () => import('pages/mallTrading/returnGoodsManage/returnGoodsAudit'),
          name: 'returnGoodsAudit',
          meta: {
            title: 'returnGoodsAudit'
          }
        },
        {
          path: 'supplierReceiving',
          component: () => import('pages/mallTrading/returnGoodsManage/supplierReceiving'),
          name: 'supplierReceiving',
          meta: {
            title: 'supplierReceiving'
          }
        },
        {
          path: 'completedReturnGoods',
          component: () => import('pages/mallTrading/returnGoodsManage/completedReturnGoods'),
          name: 'completedReturnGoods',
          meta: {
            title: 'completedReturnGoods'
          }
        },
        {
          path: 'returnGoodsAuditFailed',
          component: () => import('pages/mallTrading/returnGoodsManage/returnGoodsAuditFailed'),
          name: 'returnGoodsAuditFailed',
          meta: {
            title: 'returnGoodsAuditFailed'
          }
        }
      ]
    }
  ]
}

export default mallTradingRouter